package com.bupt.inklue.controller;

import com.bupt.inklue.dto.PracticeDTO;
import com.bupt.inklue.service.PracticeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("practice")
public class PracticeController {

    @Autowired
    private PracticeService practiceService;

    @GetMapping
    public List<PracticeDTO> getAll() {
        return practiceService.getAll();
    }
}
